package com.yswee.mallnavi.parser;

import org.json.JSONObject;

public class ValueParser extends BaseJsonParser<String> {

	private String mTag;
	
	public ValueParser(String tag) {
		mTag = tag;
	}
	
	@Override
	public String parseData(String jsonOrigin) {
		String entity = null;
		try {
			JSONObject jo = readCode(jsonOrigin);
			if(jo != null) {
				entity = getString(jo, mTag);
			}
		} catch (Exception e) {
			e.printStackTrace();
		}
		return entity;
	}

}
